user = 'jerry'
password = '123456'
count = 3

for i in range(1,count+1): # 这里直接改为判断条件range(count)就好了, 代码更简单一些
    input_user = input('账号:')
    input_password = input('密码:')
    if input_user == user and input_password == password:
        print(input_user + " login success")
        break
    else:
        if i < count:
            print('user or password is wrong')
        else:
            print('wbrong > ' + str(count))
            break